package edu.sctu.zhuyingzhi.month201506.day20150605.CalenderTest;

import java.util.Calendar;

/**
 * Created by user13 on 2015/6/5.
 */
public class JudgeTimeLong {
  private Long poor;
  public int getTimeLong(){
      Calendar calendar = Calendar.getInstance();

      Calendar calendar1 = Calendar.getInstance();
      calendar1.set(2015,06,05,11,23);

      System.out.println(calendar.getTime().getTime());
      System.out.println(calendar1.getTime().getTime());
      poor = Math.abs(calendar.getTime().getTime() - calendar1.getTime().getTime());
      return 0;
  }

    public void judgeMillisecond(){
        System.out.println((poor/100)+"毫秒");
    }

    public void  judgeSeconds(){
        System.out.println((poor/100)/1000+"秒");
    }

    public void judgeMin(){
        System.out.println((poor/1000)/(60000)+"分");
    }
    public void judgeHour(){
        System.out.println((poor/1000)/(60*60*1000)+"时");
    }

}
